package com.lagou.sqlSession;

import java.sql.SQLException;
import java.util.List;

public interface SqlSession {

    //查询所有
    public <E>List<E> selectList(String statementid, Object... params) throws SQLException, Exception;

    //根据条件查询单个
    public <T>T selectOne(String statementid, Object... params) throws SQLException, Exception;

    //更新
    public int update(String statementid, Object parameter) throws Exception;

    //删除
    public int deleteById(String statementid, Integer id) throws Exception;

    //为dao接口生成代理实现类
    public <T>T getMapper(Class<?> mapperClass);

}
